using System;
using System.Collections.Generic;
using Flaschengeist.Entities;

namespace Flaschengeist.Processes 
{
	public class CalculateScore
	{		
		public void Process(IEnumerable<LevelResult> results)
		{
			var score = 0;
			
			foreach (var result in results) {
				score += (int)result.Score;
			}
			
			Completed(score);
		}
		
		public event Action<int> Completed;
	}
}


